﻿<my:Container x:Class="Net.Chirash.Twitter.TweetZone.WindowComponents.Containers.UsersContainer"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             xmlns:my="clr-namespace:Net.Chirash.Twitter.TweetZone.WindowComponents.Containers"
             mc:Ignorable="d" 
             d:DesignHeight="300" Width="350"
             MinWidth="380"
              >
    <DockPanel x:Name="rootPanel">

        <ListBox Name="UsersListBox"
                 ScrollViewer.HorizontalScrollBarVisibility="Disabled"
                 ScrollViewer.ScrollChanged="UsersListBox_ScrollChanged"
                 ItemsSource="{Binding Collection}">
            <ListBox.ItemsPanel>
                <ItemsPanelTemplate>
                    <WrapPanel />
                </ItemsPanelTemplate>
            </ListBox.ItemsPanel>
            <ListBox.ItemTemplate>
                <DataTemplate>
                    <Image Source="{Binding ProfileImageUrl}" Width="50" Height="50" MouseLeftButtonUp="Image_MouseLeftButtonUp" >
                        <Image.ToolTip>
                            <StackPanel Margin="0,0,0,0" Orientation="Horizontal">
                                <TextBlock Padding="0" Text="{Binding Name}" />
                                <TextBlock Padding="0" Text=" / @" />
                                <TextBlock Padding="0" Text="{Binding ScreenName}" />
                            </StackPanel>
                        </Image.ToolTip>
                    </Image>

                </DataTemplate>
            </ListBox.ItemTemplate>
        </ListBox>
    </DockPanel>
</my:Container>
